package com.lmc.user.api;

import com.lmc.user.api.pojo.UserInfoRequest;
import com.lmc.user.api.pojo.UserInfoResponse;
import com.lmc.user.api.pojo.UserLoginResponse;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

@FeignClient(name = "user-service" , path = "/user")
public interface UserService {

    @RequestMapping("/login")
    public UserLoginResponse login(@RequestBody UserInfoRequest user);
    @RequestMapping("/getUserInfo")
    public UserInfoResponse getUserInfo(@RequestParam("userId") Integer userId);
    @RequestMapping("/getAuthorInfo")
    public UserInfoResponse getAuthorInfo(@RequestParam("blogId") Integer blogId);
}
